3.15 \(\int \frac{\sin (x)}{(a+a \sin (x))^2} \, dx\)

Optimal. Leaf size=33 \[ \frac{\cos (x)}{3 (a \sin (x)+a)^2}-\frac{2 \cos (x)}{3 \left (a^2 \sin (x)+a^2\right )} \]

[Out]

Cos[x]/(3*(a + a*Sin[x])^2) - (2*Cos[x])/(3*(a^2 + a^2*Sin[x]))

________________________________________________________________________________________

Rubi [A]  time = 0.0314165, antiderivative size = 33, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 11, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.182, Rules used = {2750, 2648} \[ \frac{\cos (x)}{3 (a \sin (x)+a)^2}-\frac{2 \cos (x)}{3 \left (a^2 \sin (x)+a^2\right )} \]

Antiderivative was successfully verified.

[In]

Int[Sin[x]/(a + a*Sin[x])^2,x]

[Out]

Cos[x]/(3*(a + a*Sin[x])^2) - (2*Cos[x])/(3*(a^2 + a^2*Sin[x]))

Rule 2750

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[((b
*c - a*d)*Cos[e + f*x]*(a + b*Sin[e + f*x])^m)/(a*f*(2*m + 1)), x] + Dist[(a*d*m + b*c*(m + 1))/(a*b*(2*m + 1)
), Int[(a + b*Sin[e + f*x])^(m + 1), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 -
b^2, 0] && LtQ[m, -2^(-1)]

Rule 2648

Int[((a_) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> -Simp[Cos[c + d*x]/(d*(b + a*Sin[c + d*x])), x]
/; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0]

Rubi steps

\begin{align*} \int \frac{\sin (x)}{(a+a \sin (x))^2} \, dx &=\frac{\cos (x)}{3 (a+a \sin (x))^2}+\frac{2 \int \frac{1}{a+a \sin (x)} \, dx}{3 a}\\ &=\frac{\cos (x)}{3 (a+a \sin (x))^2}-\frac{2 \cos (x)}{3 \left (a^2+a^2 \sin (x)\right )}\\ \end{align*}

Mathematica [A]  time = 0.0421223, size = 29, normalized size = 0.88 \[ -\frac{-4 \sin (x)+\sin (2 x)+\cos (x)+\cos (2 x)-3}{3 a^2 (\sin (x)+1)^2} \]

Antiderivative was successfully verified.

[In]

Integrate[Sin[x]/(a + a*Sin[x])^2,x]

[Out]

-(-3 + Cos[x] + Cos[2*x] - 4*Sin[x] + Sin[2*x])/(3*a^2*(1 + Sin[x])^2)

________________________________________________________________________________________

Maple [A]  time = 0.032, size = 27, normalized size = 0.8 \begin{align*} 4\,{\frac{1}{{a}^{2}} \left ( 1/3\, \left ( \tan \left ( x/2 \right ) +1 \right ) ^{-3}-1/2\, \left ( \tan \left ( x/2 \right ) +1 \right ) ^{-2} \right ) } \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(x)/(a+a*sin(x))^2,x)

[Out]

4/a^2*(1/3/(tan(1/2*x)+1)^3-1/2/(tan(1/2*x)+1)^2)

________________________________________________________________________________________

Maxima [B]  time = 1.07915, size = 84, normalized size = 2.55 \begin{align*} -\frac{2 \,{\left (\frac{3 \, \sin \left (x\right )}{\cos \left (x\right ) + 1} + 1\right )}}{3 \,{\left (a^{2} + \frac{3 \, a^{2} \sin \left (x\right )}{\cos \left (x\right ) + 1} + \frac{3 \, a^{2} \sin \left (x\right )^{2}}{{\left (\cos \left (x\right ) + 1\right )}^{2}} + \frac{a^{2} \sin \left (x\right )^{3}}{{\left (\cos \left (x\right ) + 1\right )}^{3}}\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)/(a+a*sin(x))^2,x, algorithm="maxima")

[Out]

-2/3*(3*sin(x)/(cos(x) + 1) + 1)/(a^2 + 3*a^2*sin(x)/(cos(x) + 1) + 3*a^2*sin(x)^2/(cos(x) + 1)^2 + a^2*sin(x)
^3/(cos(x) + 1)^3)

________________________________________________________________________________________

Fricas [B]  time = 1.39024, size = 163, normalized size = 4.94 \begin{align*} \frac{2 \, \cos \left (x\right )^{2} +{\left (2 \, \cos \left (x\right ) + 1\right )} \sin \left (x\right ) + \cos \left (x\right ) - 1}{3 \,{\left (a^{2} \cos \left (x\right )^{2} - a^{2} \cos \left (x\right ) - 2 \, a^{2} -{\left (a^{2} \cos \left (x\right ) + 2 \, a^{2}\right )} \sin \left (x\right )\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)/(a+a*sin(x))^2,x, algorithm="fricas")

[Out]

1/3*(2*cos(x)^2 + (2*cos(x) + 1)*sin(x) + cos(x) - 1)/(a^2*cos(x)^2 - a^2*cos(x) - 2*a^2 - (a^2*cos(x) + 2*a^2
)*sin(x))

________________________________________________________________________________________

Sympy [B]  time = 3.41913, size = 178, normalized size = 5.39 \begin{align*} \frac{\tan ^{3}{\left (\frac{x}{2} \right )}}{6 a^{2} \tan ^{3}{\left (\frac{x}{2} \right )} + 18 a^{2} \tan ^{2}{\left (\frac{x}{2} \right )} + 18 a^{2} \tan{\left (\frac{x}{2} \right )} + 6 a^{2}} + \frac{3 \tan ^{2}{\left (\frac{x}{2} \right )}}{6 a^{2} \tan ^{3}{\left (\frac{x}{2} \right )} + 18 a^{2} \tan ^{2}{\left (\frac{x}{2} \right )} + 18 a^{2} \tan{\left (\frac{x}{2} \right )} + 6 a^{2}} - \frac{9 \tan{\left (\frac{x}{2} \right )}}{6 a^{2} \tan ^{3}{\left (\frac{x}{2} \right )} + 18 a^{2} \tan ^{2}{\left (\frac{x}{2} \right )} + 18 a^{2} \tan{\left (\frac{x}{2} \right )} + 6 a^{2}} - \frac{3}{6 a^{2} \tan ^{3}{\left (\frac{x}{2} \right )} + 18 a^{2} \tan ^{2}{\left (\frac{x}{2} \right )} + 18 a^{2} \tan{\left (\frac{x}{2} \right )} + 6 a^{2}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)/(a+a*sin(x))**2,x)

[Out]

tan(x/2)**3/(6*a**2*tan(x/2)**3 + 18*a**2*tan(x/2)**2 + 18*a**2*tan(x/2) + 6*a**2) + 3*tan(x/2)**2/(6*a**2*tan
(x/2)**3 + 18*a**2*tan(x/2)**2 + 18*a**2*tan(x/2) + 6*a**2) - 9*tan(x/2)/(6*a**2*tan(x/2)**3 + 18*a**2*tan(x/2
)**2 + 18*a**2*tan(x/2) + 6*a**2) - 3/(6*a**2*tan(x/2)**3 + 18*a**2*tan(x/2)**2 + 18*a**2*tan(x/2) + 6*a**2)

________________________________________________________________________________________

Giac [A]  time = 1.88682, size = 28, normalized size = 0.85 \begin{align*} -\frac{2 \,{\left (3 \, \tan \left (\frac{1}{2} \, x\right ) + 1\right )}}{3 \, a^{2}{\left (\tan \left (\frac{1}{2} \, x\right ) + 1\right )}^{3}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(x)/(a+a*sin(x))^2,x, algorithm="giac")

[Out]

-2/3*(3*tan(1/2*x) + 1)/(a^2*(tan(1/2*x) + 1)^3)